sql
DROP TABLE IF EXISTS popup;
CREATE TABLE popup (
  id int(100) NOT NULL auto_increment,
  `text` blob NOT NULL,
  byuid int(100) NOT NULL default '0',
  touid int(100) NOT NULL default '0',
  unread char(1) NOT NULL default '1',
  timesent int(100) NOT NULL default '0',
  PRIMARY KEY  (id)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/////////////////////
put this link index.php under ($action=="viewuser")
if ($who!=$uid) {
echo "<a href=\"popup.php?action=send&amp;who=$who&amp;sid=$sid\">Send Popup PM</a><br/>";
}

and put this code where you want see popup msg

include("pop.php");

like in index.php


////////////////////////////////////////MAIN PAGE
if($action=="main")
{
  addvisitor();
  addonline(getuid_sid($sid),"Forum Index","index.php?action=$action");
  //saveuinfo($sid);
  
      echo "<card id=\"main\" title=\"lavalair.net\">";
  echo "<p align=\"center\">";
  //echo "<small>".date("D d M y-H:i:s")."</small><br/>";
  echo "<small>".date("D d M y - ")."</small>\n";
echo "<small><a href=\"time.php?sid=$sid\">".date("H:i")."</a></small><br/>";
  echo "<img src=\"images/logo.gif\" alt=\"*\"/><br/><small>";
  $nick = getnick_sid($sid);
  echo "Hello $nick<br/>";
/////////////////////////
/include("pop.php");/////
////////////////////////

echo "<a href=\"lists.php?action=faqs&amp;sid=$sid\">&#187;F.A.Qs&#171;</a><br/>";
  $fmsg = htmlspecialchars(getfmsg());
  echo "$fmsg</small><br/>";
  //echo "<small>The temporary chat site is ready, check<br/> <a href=\"index.php?action=viewfrm&amp;sid=$sid&amp;fid=221\">info boards&gt; Support RW</a></small>";
  echo "</p><p><small>";
  
  /////inbox data
